package com.dongdongshop.serviceImpl;

import com.dongdongshop.mapper.TbAddressMapper;
import com.dongdongshop.pojo.TbAddress;
import com.dongdongshop.service.TbAddressService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
@com.alibaba.dubbo.config.annotation.Service
public class TbAddressServiceImpl implements TbAddressService {
    @Autowired
    private TbAddressMapper tbAddressMapper;
    @Override
    public List<TbAddress> selectAll() {
        List<TbAddress> tbAddresses = tbAddressMapper.selectByExample(null);
        return tbAddresses;
    }

    @Override
    public Boolean addAll(TbAddress tbAddress) {
        int i = tbAddressMapper.insertSelective(tbAddress);
        return i>0;
    }
}
